package com.sinosoft.zyemr.entity;

import java.util.ArrayList;
import java.util.List;

public class PcaseModelEntityExample {
    protected String orderByClause;

    protected boolean distinct;

    protected List<Criteria> oredCriteria;

    public PcaseModelEntityExample() {
        oredCriteria = new ArrayList<Criteria>();
    }

    public void setOrderByClause(String orderByClause) {
        this.orderByClause = orderByClause;
    }

    public String getOrderByClause() {
        return orderByClause;
    }

    public void setDistinct(boolean distinct) {
        this.distinct = distinct;
    }

    public boolean isDistinct() {
        return distinct;
    }

    public List<Criteria> getOredCriteria() {
        return oredCriteria;
    }

    public void or(Criteria criteria) {
        oredCriteria.add(criteria);
    }

    public Criteria or() {
        Criteria criteria = createCriteriaInternal();
        oredCriteria.add(criteria);
        return criteria;
    }

    public Criteria createCriteria() {
        Criteria criteria = createCriteriaInternal();
        if (oredCriteria.size() == 0) {
            oredCriteria.add(criteria);
        }
        return criteria;
    }

    protected Criteria createCriteriaInternal() {
        Criteria criteria = new Criteria();
        return criteria;
    }

    public void clear() {
        oredCriteria.clear();
        orderByClause = null;
        distinct = false;
    }

    protected abstract static class GeneratedCriteria {
        protected List<Criterion> criteria;

        protected GeneratedCriteria() {
            super();
            criteria = new ArrayList<Criterion>();
        }

        public boolean isValid() {
            return criteria.size() > 0;
        }

        public List<Criterion> getAllCriteria() {
            return criteria;
        }

        public List<Criterion> getCriteria() {
            return criteria;
        }

        protected void addCriterion(String condition) {
            if (condition == null) {
                throw new RuntimeException("Value for condition cannot be null");
            }
            criteria.add(new Criterion(condition));
        }

        protected void addCriterion(String condition, Object value, String property) {
            if (value == null) {
                throw new RuntimeException("Value for " + property + " cannot be null");
            }
            criteria.add(new Criterion(condition, value));
        }

        protected void addCriterion(String condition, Object value1, Object value2, String property) {
            if (value1 == null || value2 == null) {
                throw new RuntimeException("Between values for " + property + " cannot be null");
            }
            criteria.add(new Criterion(condition, value1, value2));
        }

        public Criteria andIdIsNull() {
            addCriterion("ID is null");
            return (Criteria) this;
        }

        public Criteria andIdIsNotNull() {
            addCriterion("ID is not null");
            return (Criteria) this;
        }

        public Criteria andIdEqualTo(Integer value) {
            addCriterion("ID =", value, "id");
            return (Criteria) this;
        }

        public Criteria andIdNotEqualTo(Integer value) {
            addCriterion("ID <>", value, "id");
            return (Criteria) this;
        }

        public Criteria andIdGreaterThan(Integer value) {
            addCriterion("ID >", value, "id");
            return (Criteria) this;
        }

        public Criteria andIdGreaterThanOrEqualTo(Integer value) {
            addCriterion("ID >=", value, "id");
            return (Criteria) this;
        }

        public Criteria andIdLessThan(Integer value) {
            addCriterion("ID <", value, "id");
            return (Criteria) this;
        }

        public Criteria andIdLessThanOrEqualTo(Integer value) {
            addCriterion("ID <=", value, "id");
            return (Criteria) this;
        }

        public Criteria andIdIn(List<Integer> values) {
            addCriterion("ID in", values, "id");
            return (Criteria) this;
        }

        public Criteria andIdNotIn(List<Integer> values) {
            addCriterion("ID not in", values, "id");
            return (Criteria) this;
        }

        public Criteria andIdBetween(Integer value1, Integer value2) {
            addCriterion("ID between", value1, value2, "id");
            return (Criteria) this;
        }

        public Criteria andIdNotBetween(Integer value1, Integer value2) {
            addCriterion("ID not between", value1, value2, "id");
            return (Criteria) this;
        }

        public Criteria andTypeIsNull() {
            addCriterion("Type is null");
            return (Criteria) this;
        }

        public Criteria andTypeIsNotNull() {
            addCriterion("Type is not null");
            return (Criteria) this;
        }

        public Criteria andTypeEqualTo(Byte value) {
            addCriterion("Type =", value, "type");
            return (Criteria) this;
        }

        public Criteria andTypeNotEqualTo(Byte value) {
            addCriterion("Type <>", value, "type");
            return (Criteria) this;
        }

        public Criteria andTypeGreaterThan(Byte value) {
            addCriterion("Type >", value, "type");
            return (Criteria) this;
        }

        public Criteria andTypeGreaterThanOrEqualTo(Byte value) {
            addCriterion("Type >=", value, "type");
            return (Criteria) this;
        }

        public Criteria andTypeLessThan(Byte value) {
            addCriterion("Type <", value, "type");
            return (Criteria) this;
        }

        public Criteria andTypeLessThanOrEqualTo(Byte value) {
            addCriterion("Type <=", value, "type");
            return (Criteria) this;
        }

        public Criteria andTypeIn(List<Byte> values) {
            addCriterion("Type in", values, "type");
            return (Criteria) this;
        }

        public Criteria andTypeNotIn(List<Byte> values) {
            addCriterion("Type not in", values, "type");
            return (Criteria) this;
        }

        public Criteria andTypeBetween(Byte value1, Byte value2) {
            addCriterion("Type between", value1, value2, "type");
            return (Criteria) this;
        }

        public Criteria andTypeNotBetween(Byte value1, Byte value2) {
            addCriterion("Type not between", value1, value2, "type");
            return (Criteria) this;
        }

        public Criteria andDrNameIsNull() {
            addCriterion("DR_Name is null");
            return (Criteria) this;
        }

        public Criteria andDrNameIsNotNull() {
            addCriterion("DR_Name is not null");
            return (Criteria) this;
        }

        public Criteria andDrNameEqualTo(String value) {
            addCriterion("DR_Name =", value, "drName");
            return (Criteria) this;
        }

        public Criteria andDrNameNotEqualTo(String value) {
            addCriterion("DR_Name <>", value, "drName");
            return (Criteria) this;
        }

        public Criteria andDrNameGreaterThan(String value) {
            addCriterion("DR_Name >", value, "drName");
            return (Criteria) this;
        }

        public Criteria andDrNameGreaterThanOrEqualTo(String value) {
            addCriterion("DR_Name >=", value, "drName");
            return (Criteria) this;
        }

        public Criteria andDrNameLessThan(String value) {
            addCriterion("DR_Name <", value, "drName");
            return (Criteria) this;
        }

        public Criteria andDrNameLessThanOrEqualTo(String value) {
            addCriterion("DR_Name <=", value, "drName");
            return (Criteria) this;
        }

        public Criteria andDrNameLike(String value) {
            addCriterion("DR_Name like", value, "drName");
            return (Criteria) this;
        }

        public Criteria andDrNameNotLike(String value) {
            addCriterion("DR_Name not like", value, "drName");
            return (Criteria) this;
        }

        public Criteria andDrNameIn(List<String> values) {
            addCriterion("DR_Name in", values, "drName");
            return (Criteria) this;
        }

        public Criteria andDrNameNotIn(List<String> values) {
            addCriterion("DR_Name not in", values, "drName");
            return (Criteria) this;
        }

        public Criteria andDrNameBetween(String value1, String value2) {
            addCriterion("DR_Name between", value1, value2, "drName");
            return (Criteria) this;
        }

        public Criteria andDrNameNotBetween(String value1, String value2) {
            addCriterion("DR_Name not between", value1, value2, "drName");
            return (Criteria) this;
        }

        public Criteria andModelNameIsNull() {
            addCriterion("Model_Name is null");
            return (Criteria) this;
        }

        public Criteria andModelNameIsNotNull() {
            addCriterion("Model_Name is not null");
            return (Criteria) this;
        }

        public Criteria andModelNameEqualTo(String value) {
            addCriterion("Model_Name =", value, "modelName");
            return (Criteria) this;
        }

        public Criteria andModelNameNotEqualTo(String value) {
            addCriterion("Model_Name <>", value, "modelName");
            return (Criteria) this;
        }

        public Criteria andModelNameGreaterThan(String value) {
            addCriterion("Model_Name >", value, "modelName");
            return (Criteria) this;
        }

        public Criteria andModelNameGreaterThanOrEqualTo(String value) {
            addCriterion("Model_Name >=", value, "modelName");
            return (Criteria) this;
        }

        public Criteria andModelNameLessThan(String value) {
            addCriterion("Model_Name <", value, "modelName");
            return (Criteria) this;
        }

        public Criteria andModelNameLessThanOrEqualTo(String value) {
            addCriterion("Model_Name <=", value, "modelName");
            return (Criteria) this;
        }

        public Criteria andModelNameLike(String value) {
            addCriterion("Model_Name like", value, "modelName");
            return (Criteria) this;
        }

        public Criteria andModelNameNotLike(String value) {
            addCriterion("Model_Name not like", value, "modelName");
            return (Criteria) this;
        }

        public Criteria andModelNameIn(List<String> values) {
            addCriterion("Model_Name in", values, "modelName");
            return (Criteria) this;
        }

        public Criteria andModelNameNotIn(List<String> values) {
            addCriterion("Model_Name not in", values, "modelName");
            return (Criteria) this;
        }

        public Criteria andModelNameBetween(String value1, String value2) {
            addCriterion("Model_Name between", value1, value2, "modelName");
            return (Criteria) this;
        }

        public Criteria andModelNameNotBetween(String value1, String value2) {
            addCriterion("Model_Name not between", value1, value2, "modelName");
            return (Criteria) this;
        }

        public Criteria andPriDepictIsNull() {
            addCriterion("PRI_DEPICT is null");
            return (Criteria) this;
        }

        public Criteria andPriDepictIsNotNull() {
            addCriterion("PRI_DEPICT is not null");
            return (Criteria) this;
        }

        public Criteria andPriDepictEqualTo(String value) {
            addCriterion("PRI_DEPICT =", value, "priDepict");
            return (Criteria) this;
        }

        public Criteria andPriDepictNotEqualTo(String value) {
            addCriterion("PRI_DEPICT <>", value, "priDepict");
            return (Criteria) this;
        }

        public Criteria andPriDepictGreaterThan(String value) {
            addCriterion("PRI_DEPICT >", value, "priDepict");
            return (Criteria) this;
        }

        public Criteria andPriDepictGreaterThanOrEqualTo(String value) {
            addCriterion("PRI_DEPICT >=", value, "priDepict");
            return (Criteria) this;
        }

        public Criteria andPriDepictLessThan(String value) {
            addCriterion("PRI_DEPICT <", value, "priDepict");
            return (Criteria) this;
        }

        public Criteria andPriDepictLessThanOrEqualTo(String value) {
            addCriterion("PRI_DEPICT <=", value, "priDepict");
            return (Criteria) this;
        }

        public Criteria andPriDepictLike(String value) {
            addCriterion("PRI_DEPICT like", value, "priDepict");
            return (Criteria) this;
        }

        public Criteria andPriDepictNotLike(String value) {
            addCriterion("PRI_DEPICT not like", value, "priDepict");
            return (Criteria) this;
        }

        public Criteria andPriDepictIn(List<String> values) {
            addCriterion("PRI_DEPICT in", values, "priDepict");
            return (Criteria) this;
        }

        public Criteria andPriDepictNotIn(List<String> values) {
            addCriterion("PRI_DEPICT not in", values, "priDepict");
            return (Criteria) this;
        }

        public Criteria andPriDepictBetween(String value1, String value2) {
            addCriterion("PRI_DEPICT between", value1, value2, "priDepict");
            return (Criteria) this;
        }

        public Criteria andPriDepictNotBetween(String value1, String value2) {
            addCriterion("PRI_DEPICT not between", value1, value2, "priDepict");
            return (Criteria) this;
        }

        public Criteria andLocalDisHisIsNull() {
            addCriterion("LOCAL_DIS_HIS is null");
            return (Criteria) this;
        }

        public Criteria andLocalDisHisIsNotNull() {
            addCriterion("LOCAL_DIS_HIS is not null");
            return (Criteria) this;
        }

        public Criteria andLocalDisHisEqualTo(String value) {
            addCriterion("LOCAL_DIS_HIS =", value, "localDisHis");
            return (Criteria) this;
        }

        public Criteria andLocalDisHisNotEqualTo(String value) {
            addCriterion("LOCAL_DIS_HIS <>", value, "localDisHis");
            return (Criteria) this;
        }

        public Criteria andLocalDisHisGreaterThan(String value) {
            addCriterion("LOCAL_DIS_HIS >", value, "localDisHis");
            return (Criteria) this;
        }

        public Criteria andLocalDisHisGreaterThanOrEqualTo(String value) {
            addCriterion("LOCAL_DIS_HIS >=", value, "localDisHis");
            return (Criteria) this;
        }

        public Criteria andLocalDisHisLessThan(String value) {
            addCriterion("LOCAL_DIS_HIS <", value, "localDisHis");
            return (Criteria) this;
        }

        public Criteria andLocalDisHisLessThanOrEqualTo(String value) {
            addCriterion("LOCAL_DIS_HIS <=", value, "localDisHis");
            return (Criteria) this;
        }

        public Criteria andLocalDisHisLike(String value) {
            addCriterion("LOCAL_DIS_HIS like", value, "localDisHis");
            return (Criteria) this;
        }

        public Criteria andLocalDisHisNotLike(String value) {
            addCriterion("LOCAL_DIS_HIS not like", value, "localDisHis");
            return (Criteria) this;
        }

        public Criteria andLocalDisHisIn(List<String> values) {
            addCriterion("LOCAL_DIS_HIS in", values, "localDisHis");
            return (Criteria) this;
        }

        public Criteria andLocalDisHisNotIn(List<String> values) {
            addCriterion("LOCAL_DIS_HIS not in", values, "localDisHis");
            return (Criteria) this;
        }

        public Criteria andLocalDisHisBetween(String value1, String value2) {
            addCriterion("LOCAL_DIS_HIS between", value1, value2, "localDisHis");
            return (Criteria) this;
        }

        public Criteria andLocalDisHisNotBetween(String value1, String value2) {
            addCriterion("LOCAL_DIS_HIS not between", value1, value2, "localDisHis");
            return (Criteria) this;
        }

        public Criteria andAnamnesisIsNull() {
            addCriterion("ANAMNESIS is null");
            return (Criteria) this;
        }

        public Criteria andAnamnesisIsNotNull() {
            addCriterion("ANAMNESIS is not null");
            return (Criteria) this;
        }

        public Criteria andAnamnesisEqualTo(String value) {
            addCriterion("ANAMNESIS =", value, "anamnesis");
            return (Criteria) this;
        }

        public Criteria andAnamnesisNotEqualTo(String value) {
            addCriterion("ANAMNESIS <>", value, "anamnesis");
            return (Criteria) this;
        }

        public Criteria andAnamnesisGreaterThan(String value) {
            addCriterion("ANAMNESIS >", value, "anamnesis");
            return (Criteria) this;
        }

        public Criteria andAnamnesisGreaterThanOrEqualTo(String value) {
            addCriterion("ANAMNESIS >=", value, "anamnesis");
            return (Criteria) this;
        }

        public Criteria andAnamnesisLessThan(String value) {
            addCriterion("ANAMNESIS <", value, "anamnesis");
            return (Criteria) this;
        }

        public Criteria andAnamnesisLessThanOrEqualTo(String value) {
            addCriterion("ANAMNESIS <=", value, "anamnesis");
            return (Criteria) this;
        }

        public Criteria andAnamnesisLike(String value) {
            addCriterion("ANAMNESIS like", value, "anamnesis");
            return (Criteria) this;
        }

        public Criteria andAnamnesisNotLike(String value) {
            addCriterion("ANAMNESIS not like", value, "anamnesis");
            return (Criteria) this;
        }

        public Criteria andAnamnesisIn(List<String> values) {
            addCriterion("ANAMNESIS in", values, "anamnesis");
            return (Criteria) this;
        }

        public Criteria andAnamnesisNotIn(List<String> values) {
            addCriterion("ANAMNESIS not in", values, "anamnesis");
            return (Criteria) this;
        }

        public Criteria andAnamnesisBetween(String value1, String value2) {
            addCriterion("ANAMNESIS between", value1, value2, "anamnesis");
            return (Criteria) this;
        }

        public Criteria andAnamnesisNotBetween(String value1, String value2) {
            addCriterion("ANAMNESIS not between", value1, value2, "anamnesis");
            return (Criteria) this;
        }

        public Criteria andIndividualHisIsNull() {
            addCriterion("INDIVIDUAL_HIS is null");
            return (Criteria) this;
        }

        public Criteria andIndividualHisIsNotNull() {
            addCriterion("INDIVIDUAL_HIS is not null");
            return (Criteria) this;
        }

        public Criteria andIndividualHisEqualTo(String value) {
            addCriterion("INDIVIDUAL_HIS =", value, "individualHis");
            return (Criteria) this;
        }

        public Criteria andIndividualHisNotEqualTo(String value) {
            addCriterion("INDIVIDUAL_HIS <>", value, "individualHis");
            return (Criteria) this;
        }

        public Criteria andIndividualHisGreaterThan(String value) {
            addCriterion("INDIVIDUAL_HIS >", value, "individualHis");
            return (Criteria) this;
        }

        public Criteria andIndividualHisGreaterThanOrEqualTo(String value) {
            addCriterion("INDIVIDUAL_HIS >=", value, "individualHis");
            return (Criteria) this;
        }

        public Criteria andIndividualHisLessThan(String value) {
            addCriterion("INDIVIDUAL_HIS <", value, "individualHis");
            return (Criteria) this;
        }

        public Criteria andIndividualHisLessThanOrEqualTo(String value) {
            addCriterion("INDIVIDUAL_HIS <=", value, "individualHis");
            return (Criteria) this;
        }

        public Criteria andIndividualHisLike(String value) {
            addCriterion("INDIVIDUAL_HIS like", value, "individualHis");
            return (Criteria) this;
        }

        public Criteria andIndividualHisNotLike(String value) {
            addCriterion("INDIVIDUAL_HIS not like", value, "individualHis");
            return (Criteria) this;
        }

        public Criteria andIndividualHisIn(List<String> values) {
            addCriterion("INDIVIDUAL_HIS in", values, "individualHis");
            return (Criteria) this;
        }

        public Criteria andIndividualHisNotIn(List<String> values) {
            addCriterion("INDIVIDUAL_HIS not in", values, "individualHis");
            return (Criteria) this;
        }

        public Criteria andIndividualHisBetween(String value1, String value2) {
            addCriterion("INDIVIDUAL_HIS between", value1, value2, "individualHis");
            return (Criteria) this;
        }

        public Criteria andIndividualHisNotBetween(String value1, String value2) {
            addCriterion("INDIVIDUAL_HIS not between", value1, value2, "individualHis");
            return (Criteria) this;
        }
    }

    public static class Criteria extends GeneratedCriteria {

        protected Criteria() {
            super();
        }
    }

    public static class Criterion {
        private String condition;

        private Object value;

        private Object secondValue;

        private boolean noValue;

        private boolean singleValue;

        private boolean betweenValue;

        private boolean listValue;

        private String typeHandler;

        public String getCondition() {
            return condition;
        }

        public Object getValue() {
            return value;
        }

        public Object getSecondValue() {
            return secondValue;
        }

        public boolean isNoValue() {
            return noValue;
        }

        public boolean isSingleValue() {
            return singleValue;
        }

        public boolean isBetweenValue() {
            return betweenValue;
        }

        public boolean isListValue() {
            return listValue;
        }

        public String getTypeHandler() {
            return typeHandler;
        }

        protected Criterion(String condition) {
            super();
            this.condition = condition;
            this.typeHandler = null;
            this.noValue = true;
        }

        protected Criterion(String condition, Object value, String typeHandler) {
            super();
            this.condition = condition;
            this.value = value;
            this.typeHandler = typeHandler;
            if (value instanceof List<?>) {
                this.listValue = true;
            } else {
                this.singleValue = true;
            }
        }

        protected Criterion(String condition, Object value) {
            this(condition, value, null);
        }

        protected Criterion(String condition, Object value, Object secondValue, String typeHandler) {
            super();
            this.condition = condition;
            this.value = value;
            this.secondValue = secondValue;
            this.typeHandler = typeHandler;
            this.betweenValue = true;
        }

        protected Criterion(String condition, Object value, Object secondValue) {
            this(condition, value, secondValue, null);
        }
    }
}